import re

if __name__ == '__main__':
    # 要匹配的文本内容
    text = "Does this text match the pattern？"
    print(repr(text))
    print('Text: {!r}\n'.format(text))

    regexes = [
        re.compile(p) for p in ['this', 'that']
    ]

    for regex in regexes:
        print('Seeking "{}" ->'.format(regex.pattern), end=' ')

        if regex.search(text):
            print('match!')
        else:
            print('no match')

